<?php


namespace App\Models;


use Illuminate\Database\Eloquent\Model;

/**
 * Class OrderPack
 * @package App\Models
 * @property Package $package
 * @author luffyzhao@vip.126.com
 */
class OrderPack extends Model
{
    protected $table = 'order_pack';

    protected $fillable = ['package_id', 'consumable_json'];

    protected $casts = ['consumable_json' => 'json'];

    /**
     * @return \Illuminate\Database\Eloquent\Relations\BelongsTo
     * @author luffyzhao@vip.126.com
     */
    public function package(){
        return $this->belongsTo(Package::class);
    }
}